package com.eb.GoodsClient;

import com.eb.pojo.Goods;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import java.util.List;

@FeignClient(name = "goods")
public interface GoodsClicent {


    @RequestMapping(value = "/goods/id/{id}",method = RequestMethod.GET)
    public Goods findBygoods(@PathVariable("id")int id);

    @RequestMapping(value = "/goods/list",method = RequestMethod.GET)
    public List<Goods> list();
}
